package com.huaxin.hxmodulesystem.service;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService;
import com.huaxin.hxmodulesystem.dto.ResponseResult;
import com.huaxin.hxmodulesystem.dto.request.AddOperationLogReqDTO;
import com.huaxin.hxmodulesystem.models.OperationLog;

public interface OperationLogService extends IService<OperationLog> {
    /**
     * 新增操作日志
     *
     * @param operationLog
     * @return
     */
    boolean addOperationLog(AddOperationLogReqDTO operationLog);

    /**
     * 获取操作日志列表
     *
     * @param pageNum
     * @param pageSize
     * @param userId
     * @param operationType
     * @return
     */
    Page<OperationLog> getOperationLogList(Integer pageNum, Integer pageSize, String userId, Integer operationType, String startTime, String endTime);

    /**
     * 获取操作日志详情
     *
     * @param id
     * @return
     */
    OperationLog getOperationLogDetail(String id);

    /**
     * 删除操作日志
     *
     * @param id
     * @return
     */
    ResponseResult<String> deleteOperationLog(String id);

    /**
     * 清理操作日志
     */
    ResponseResult<String> clearOperationLogs();
}